Refactor to remove Leetcode endpoint and related services #47#49
Merged
JRS296 merged 3 commits intoDijkstra-Edu:qafrom Mar 17, 2026
Merged
Refactor to remove Leetcode endpoint and related services #47#49JRS296 merged 3 commits intoDijkstra-Edu:qafrom
JRS296 merged 3 commits intoDijkstra-Edu:qafrom
Conversation
JRS296
reviewed
Mar 7, 2026
Member
There was a problem hiding this comment.
@AmanDeol7 we do not directly edit out older versions of DB migrations. You will need to generate a new version from the updated schema. Can you have a look at the instructions on the Readme for creating a new version on Alembic?
JRS296
reviewed
Mar 7, 2026
JRS296
reviewed
Mar 7, 2026
JRS296
requested changes
Mar 7, 2026
Member
JRS296
left a comment
There was a problem hiding this comment.
Kindly make the requested changes, and let me know if you have trouble with Alembic
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
… #47
Remove LeetCode Integration - Complete Feature Cleanup
📋 Description
This pull request completely removes the LeetCode profile integration feature from the Dataforge application. The refactoring includes cleanup of controllers, services, repositories, data models, DTOs, and database migrations.
🎯 Objective
Deprecate and remove the LeetCode profile feature to streamline the codebase and reduce maintenance burden.
📦 Changes Summary
Backend API
app/Controllers/User/leetcode_controller.py(105 lines)/sync/{profile_id}/{lc_username}Service Layer
app/Services/User/leetcode_service.pyLeetCodeServiceclass and all its methodsgetAllLeetcodeData()for API fetching (read-only)Data Access Layer
app/Repository/User/leetcode_repository.py(241 lines)LeetcodeRepository- core CRUD operationsLeetcodeBadgeRepository- badge managementLeetcodeTagRepository- tag management with filtering and sortingData Models
app/Schema/SQL/Models/models.pyLeetcodemodel classLeetcodeBadgesmodel classLeetcodeTagsmodel classProfile.leetcodeEnums & Constants
Modified:
app/Schema/SQL/Enums/enums.pyLeetcodeTagCategoryenum (FUNDAMENTAL, INTERMEDIATE, ADVANCED)Modified:
app/Utils/error_codes.pyUSER_LEETCODE_DB_A01/A02/A03(database errors)USER_LEETCODE_SRV_A01/A02(service errors)USER_LEETCODE_VAL_A01(validation error)USER_LEETCODE_NF_A01/A02/A03(not found errors)Exception Handling
app/Utils/Exceptions/user_exceptions.pyLeetcodeNotFoundexceptionLeetcodeBadgeNotFoundexceptionLeetcodeTagNotFoundexceptionEntity DTOs
app/Entities/leetcode_entity.py(196 lines)CreateLeetcode,UpdateLeetcode,ReadLeetcodeDTOsCreateLeetcodeBadge,UpdateLeetcodeBadge,ReadLeetcodeBadgeDTOsCreateLeetcodeTag,UpdateLeetcodeTag,ReadLeetcodeTagDTOsReadLeetcodeWithRelationsaggregated DTOApplication Configuration
app/main.pyleetcode_controllerapp.include_router(leetcode_controller.router)Database
app/migrations/versions/a02260f2e326_drop_leetcode_models_and_tables.pyLeetcodeTagstableLeetcodeBadgestableLeetcodetable📝 Breaking Changes
The following API endpoints are removed:
POST /Dijkstra/v1/leetcode/sync/{profile_id}/{lc_username}GET /Dijkstra/v1/leetcode/id/{leetcode_id}GET /Dijkstra/v1/leetcode/{github_username}GET /Dijkstra/v1/leetcode/profile/{profile_id}DELETE /Dijkstra/v1/leetcode/{leetcode_id}/badges/*/tags/*📊 Code Impact
🚀 Deployment Notes
Related Issue: #47
Type: Refactoring / Deprecation
Scope: User Module - LeetCode Integration